
{% extends 'setting/base.html' %}


{% block selfstyle %}

     <link href="{{ STATIC_URL }}css/fancybox/jquery.fancybox-1.3.4.css" rel="stylesheet" type="text/css" media="screen" />

{% endblock %}


{% block content %}
         <div class="setting">
                    <form method="post" name='school_form' action="/i/">
                        <div class="home" >
                            <div class="first" >
                                <label>学校</label>
                                <a class="virtual_select college" href="#sc" style="background: none;cursor: pointer" >{{ cname }}</a>
                                {{ form.college }}
                            </div>
                            <div class="second" >
                                <span class="virtual_select school">{{ sname }}</span>
                                <ul id="school_options"> 
                                    {% for school in schools %}
                                    <li onclick='set_school({{school.scid}})' >{{ school.name }}</li>
                                    {% endfor %}
                                </ul>
                                {{ form.school }}
                            </div>
                        </div>

                        <div class="home" >
                            <div class="first" >
                                <label>入学年份</label>
                                <span class="virtual_select start_year">{{ start }}</span>
                                <ul id="start_year_options"> 
                                    {% for year in school_years %}
                                      <li>{{ year }}</li> 
                                    {% endfor %}
                                </ul>
                                {{ form.start_year }}
                            </div>
                            <div class="second" >
                                <span class="virtual_select end_year">{{ end }}</span>
                                <ul id="end_year_options"> 
                                     {% for year in school_years %}
                                      <li>{{ year }}</li> 
                                    {% endfor %}
                                </ul>
                                {{ form.end_year }}
                            </div>
                        </div>
                        
                         <p>
                            <input type="button" class="action" onclick='post_school_data()' value="保存">   
                        </p> 
                    </form>
                </div>

                {% include 'setting/school_pop.html' %}
{% endblock %}


 {% block selfscript %}

    <script src="{{ STATIC_URL }}js/jquery.fancybox-1.3.4.js" ></script>     
    <script type="text/javascript">

              $(document).ready(function(){
                        $("a.college").fancybox({
                            'overlayShow'   : true,
                            'overlayOpacity': 0.5
                        });
                });
    </script>


{% endblock %}
